Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misc fixes #24

Merged
merged 2 commits into from
Dec 23, 2020
Merged

Misc fixes #24

merged 2 commits into from
Dec 23, 2020

Conversation

sysvinit
Copy link
Contributor

These commits are some fixes I've applied locally. Uploaded files are by default created with the executable bit set, so I've changed the code to avoid doing this, and there's common logic in the GET and HEAD request handling, which I've merged into a single path.

There is shared logic in the GET and HEAD codepaths surrounding stat()ing the
requested file, and sanity checking that the request is indeed valid. This
commit de-duplicates this code into a single path.
There's no particular reason why uploaded files should have the executable bit
set, and doing so probably has vague security implications.
Copy link
Owner

@ThomasLeister ThomasLeister left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Valid "cleanup" changes. Thanks!

@ThomasLeister ThomasLeister merged commit 263c6ff into ThomasLeister:develop Dec 23, 2020
@sysvinit sysvinit deleted the misc-fixes branch December 24, 2020 01:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants